<?php

	$dbinfo = Configure::read('dbinfo');
	
	if (preg_match("/^pdo-(mysql|pgsql)$/", $dbinfo['dbdriver'])) {
		include(CHERRY_BASE . "/lib/core/db_connection_pdo.php");
	} else if (preg_match("/^(mysql|mysqli|pgsql)$/", $dbinfo['dbdriver'])) {
		include(CHERRY_BASE . "/lib/core/db_connection_native.php");
	} else {
		throw new CherryException($dbinfo['dbdriver']." doesn't exist", 500);
	}
	
?>
